﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Admin/AdminMaster.Master" AutoEventWireup="true" CodeBehind="AdminHotPosition.aspx.cs" Inherits="TravelLink.WebApp.Admin.AdminHotPosition" %>
<%@ Register assembly="DevExpress.Web.ASPxGridView.v11.1, Version=11.1.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" namespace="DevExpress.Web.ASPxGridView" tagprefix="dx" %>
<%@ Register assembly="DevExpress.Web.ASPxEditors.v11.1, Version=11.1.4.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" namespace="DevExpress.Web.ASPxEditors" tagprefix="dx" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <dx:ASPxGridView ID="ASPxGridView1" runat="server" AutoGenerateColumns="False" 
        DataSourceID="LinqDataSource1" KeyFieldName="PositionCode" 
        onhtmldatacellprepared="ASPxGridView1_HtmlDataCellPrepared">
        <Columns>
            <dx:GridViewCommandColumn ButtonType="Button" Caption="操作" VisibleIndex="5">
                <EditButton Text="编辑" Visible="True">
                </EditButton>
                <DeleteButton Text="删除" Visible="True">
                </DeleteButton>
                <CancelButton Text="取消">
                </CancelButton>
                <UpdateButton Text="保存" Visible="True">
                </UpdateButton>
            </dx:GridViewCommandColumn>
            <dx:GridViewDataTextColumn Caption="职位编号" FieldName="PositionCode" 
                ReadOnly="True" VisibleIndex="0">
                <EditFormSettings Visible="False" />
            </dx:GridViewDataTextColumn>
            <dx:GridViewDataImageColumn Caption="图片" FieldName="Image" VisibleIndex="3">
                <PropertiesImage ImageUrlFormatString="~\Images\HtmlInfo\{0}">
                </PropertiesImage>
                <EditItemTemplate>
                    <table cellpadding="0" cellspacing="0">

                                                                    <tr>
                                                                        <td>
                                                                            <asp:FileUpload ID="FileUploadb" runat="server" />
                                                                        </td>
                                                                        <td>
                                                                            <asp:Image ID="imgb" runat="server" Height="120px" Width="120px" ImageUrl='<%# "/Images/HtmlInfo/"+Eval("Image")%>' /></td>
                                                                        <td>
                                                                            <dx:ASPxButton ID="abtnuploadblogo" runat="server" 
                                                                                onclick="abtnuploadblogo_Click" Text="上传">
                                                                            </dx:ASPxButton>
                                                                        </td>
                                                                    </tr>
                                                                </table>
                </EditItemTemplate>
            </dx:GridViewDataImageColumn>
            <dx:GridViewDataTextColumn Caption="序号" FieldName="SortId" VisibleIndex="4">
            </dx:GridViewDataTextColumn>
            <dx:GridViewDataTextColumn Caption="职位" VisibleIndex="2">
                <EditFormSettings Visible="False" />
            </dx:GridViewDataTextColumn>
            <dx:GridViewDataTextColumn Caption="公司" VisibleIndex="1">
                <EditFormSettings Visible="False" />
            </dx:GridViewDataTextColumn>
        </Columns>
    </dx:ASPxGridView>
    <asp:LinqDataSource ID="LinqDataSource1" runat="server" 
        ContextTypeName="TravelLink.DAL.TravelLinkDBDataContext" EnableDelete="True" 
        EnableInsert="True" EnableUpdate="True" EnableViewState="False" 
        EntityTypeName="" OrderBy="SortId" TableName="TL_HotPosition">
    </asp:LinqDataSource>
</asp:Content>
